@if (snapshot.previewNameSelected) {
    <span class="ms-2">{{ "common.preview" | sqxTranslate }}:</span>
    <div class="btn-group ms-2" #buttonGroup>
        <button class="btn btn-secondary" (click)="follow(snapshot.previewNameSelected)" type="button">
            <i class="icon-external-link"></i> {{ snapshot.previewNameSelected }}
        </button>
        @if (snapshot.previewNamesMore.length > 0) {
            <div class="btn-group">
                <button class="btn btn-secondary dropdown-toggle" (click)="dropdown.toggle()" type="button"></button>
                <sqx-dropdown-menu scrollY="true" [sqxAnchoredTo]="buttonGroup" *sqxModal="dropdown; closeAlways: true">
                    @for (name of snapshot.previewNamesMore; track name) {
                        <a class="dropdown-item" (click)="follow(name)">{{ name }}</a>
                    }
                </sqx-dropdown-menu>
            </div>
        }
    </div>
}
